﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HomePageProducts.ascx.cs" Inherits="CS424_9pts.Modules.HomePageProducts" %>
<div class="home-page-product-grid">
    <div class="boxtitle">
        FEATURED PRODUCTS
    </div>
    <div class="clear">
    </div>
    <asp:DataList ID="dlCatalog" runat="server" RepeatColumns="3" RepeatDirection="Horizontal"
        RepeatLayout="Table"  DataSourceID="BrandName" ItemStyle-CssClass="item-box" EnableViewState="false">
        <ItemTemplate>
            <div class="product-item">
                <div class="picture">
                      <a href='<%#Eval("ImagesName") %>'>
                        <asp:Image ID="hlImageLink" runat="server" ImageUrl='<%#Eval("ImagesName")  %>' Height="100px" Width="125px"/>
                    </a>
                </div>
                <h2 class="product-title">
                    <asp:HyperLink ID="hlProduct" runat="server" Text='<%#Eval("Description") %>' NavigateUrl='<%# Eval("BrandID") %>' />
                </h2>
            </div>
        </ItemTemplate>
    </asp:DataList>
    <asp:SqlDataSource ID="BrandName" runat="server" ConnectionString="<%$ ConnectionStrings:CarManagementConnectionString %>"
    SelectCommand="SELECT [BrandID], [BrandName], [ImagesName], [Description] FROM [Brand]">
</asp:SqlDataSource>

</div>
